import Http from '@/axios';

export default class FileApi {
    public static test(data: FormData) {
        return Http.post(this.handleUrl('test'), data);
    }

    public static uploadChunkFile(data: FormData) {
        return Http.post(this.handleUrl('chunk/upload'), data);
    }

    private static handleUrl(relativeUrl: string) {
        return `api/file/${relativeUrl}`;
    }
}
